home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Netware Super Library
/
Netware Super Library.iso
/
nov_info
/
fyi8
/
073118.dos
< prev
next >
Wrap
Text File
|
1990-07-31
|
2KB
|
45 lines
Number: A4TH071790U140V52
Subject: Mapping a Search Drive in a Child Process
Date: July 25, 1990
OS Version: All
Shell Version: All
- - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PROBLEM: This is regarding problems mapping a search drive in a child
process. Spawned process does not work with shell. Try this sequence of
commands:
1) Execute a program that spawns a process for example:
{
spawnlp(P_WAIT,"COMMAND.COM","/C".'\O');
printf("There it goes !!!");
}
2) Then type PATH
3) Then do MAP INS S#:=<server name>/SYS:<directory>
4) Then type PATH.
At this point it will not update the path. If you type EXIT and then
do a path, it will show the new drive.
SOLUTION: First of all, it appears that the spawn is working, or you
wouldn't be executing path, map, etc. Second, the map updates the master
environment only, not the current environment, and not the parent
environment. When you run the set command, it is looking at the current
environment, which is the spawned DOS. This is the parent environment when
MAP runs. However, when the shell was loaded, it located the master
environment and saved a pointer to it. When map runs, it requests this
pointer of the shell, and uses it to update the environment.
There is no work around for this, as the spawning of
secondary command processors is not a simple matter. To effectively change
this would require resizeable environments, which DOS does not provide.
In other words, it's not a bug, so there's no FIX.
(X) This information was verified verbally.
(X) This information was verified by Engineering.